<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<base href="<%=basePath%>">
<meta name="viewport"
	content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
<title>云盘项目</title>
<link href="${pageContext.request.contextPath}/statics/css/public.css"
	type="text/css" rel="stylesheet">
<link href="${pageContext.request.contextPath}/statics/css/houtai.css"
	type="text/css" rel="stylesheet">
<link
	href="${pageContext.request.contextPath}/statics/css/smartMenu.css"
	type="text/css" rel="stylesheet">
<link href="${pageContext.request.contextPath}/statics/css/admin.css"
	type="text/css" rel="stylesheet">
<link rel="stylesheet"
	href="http://cdn.static.runoob.com/libs/bootstrap/3.3.7/css/bootstrap.min.css">
<script
	src="http://cdn.static.runoob.com/libs/jquery/2.1.1/jquery.min.js"></script>
<script
	src="http://cdn.static.runoob.com/libs/bootstrap/3.3.7/js/bootstrap.min.js"></script>

</head>

<body>
	<div id="admin">
		<div class="ad-menu" id="ad-menu">
			<div class="ad-logo">
				<img
					src="${pageContext.request.contextPath}/statics/images/logo2.png"
					height="103" width="130">
			</div>
			<div class="ad-list">
				<ul>
					<li><a href="showFile?typeId=0" target='main'><div
								class="li-item">
								<em class="scm li-ico ic1"></em>全部文件
							</div></a></li>
					<li><a href="showFile?typeId=1" target='main'><div
								class="li-item">
								<em class="scm li-ico ic7"></em>文档管理
							</div></a></li>
					<li><a href="showFile?typeId=2" target='main'><div
								class="li-item">
								<em class="scm li-ico ic3"></em>视频管理
							</div></a></li>
					<li><a href="showFile?typeId=3" target='main'>
							<div class="li-item">
								<em class="scm li-ico ic4"></em>图片管理
							</div>
					</a></li>
					<li><a href="showFile?typeId=4" target='main'>
							<div class="li-item">
								<em class="scm li-ico ic5"></em>音乐管理
							</div>
					</a></li>
					<li><a href="folderList" target='main'><div
								class="li-item">
								<em class="scm li-ico ic2"></em>文件夹管理
							</div></a></li>
					<li><a href="showFile?typeId=5" target='main'>
							<div class="li-item">
								<em class="scm li-ico ic5"></em>其他管理
							</div>
					</a></li>
					<li><a href="${pageContext.request.contextPath}/shareList"
						target='main' method="post">
							<div class="li-item">
								<em class="scm li-ico ic6"></em>分享管理
							</div>
					</a></li>

				</ul>
				<hr />
				<div>
					<ul>
						<li
							style="margin-top: 10px; margin-left: 30px; color: #FFFFFF; fon t-size: 1.8ex;">空间使用情况</li>
						<li
							style="margin-top: 15px; margin-left: 30px; color: #FFFFFF; font-size: 1.8ex;">空间大小：<span
							class="count c_max" style="color: red;">【<fmt:formatNumber
									type="number" value="${10}" pattern="0.00"
									maxFractionDigits="2" />】&nbsp;&nbsp;MB
						</span></li>
						<li
							style="margin-top: 15px; margin-left: 30px; color: #FFFFFF; font-size: 1.8ex;">剩余空间：<span
							class="count c_leave" style="color: red;">【<fmt:formatNumber
									type="number"
									value="${(1024*1024*10 - sessionScope.used_size)/(1024*1024)}"
									pattern="0.00" maxFractionDigits="2" />】&nbsp;&nbsp;MB
						</span></li>
					</ul>
				</div>
			</div>
		</div>
		<div class="ad-comment-box" id="ad-comment">
			<div class="ad-top-comment">
				<div class="ad-message">
					<div class="ad-top-left">
						<div class="ad-change-btn">
							<a id="ad-list" href="javascript:;" class="scm ad-list-btn"></a>
						</div>

						<div class="ad-search-box clear">
							<div class="ad-search-sel">
								<span style="margin-left: 10px;">我的网盘</span> <span
									style="margin-left: 50px;">传输列表</span> <a
									href="${pageContext.request.contextPath}/share" target="main"
									method="post"> <span style="margin-left: 50px;">好友分享</span></a>
							</div>
							<div class="ad-search-cha">
								<input type="text" class="ad-search-input"
									placeholder="请输入你要查找的内容"> <input type="submit"
									class="scm ad-search-btn" value="">
							</div>
						</div>
					</div>
					<div class="ad-top-right">

						<div class="ad-welcom">
							<div class="ad-wel-img">
								<img
									src="${pageContext.request.contextPath}/statics/images/min_logo.png"
									height="36" width="36">
							</div>
							<div class="ad-wel-text">
								<div class="font-wel">
									欢迎您！<strong>${sessionScope.existUser.userName }</strong>
								</div>
								<div class="font-wel">
									<a href="javascript:;"><strong>【退出】</strong></a>
								</div>
							</div>
						</div>
					</div>
				</div>
				<div class="ad-main-nav-box">
					<ul id="breadcrumbs-three">
						<li title="首页"><a href="javascript:;" class="dot">首页</a></li>
					</ul>
					<span class="ad-main-wraper .J_menuItems">
						<ul class="ad-main-list" id="ad-main">



							<button class="upload" data-toggle="modal" data-target="#myModal"
								style="margin-left: 150px;">上传</button>

							<div class="modal fade" id="myModal" tabindex="-1" role="dialog"
								aria-labelledby="myModalLabel" aria-hidden="true">
								<div class="modal-dialog">
									<div class="modal-content">
										<div class="modal-header">
											<button type="button" class="close" data-dismiss="modal"
												aria-hidden="true">&times;</button>
											<h4 class="modal-title" id="myModalLabel">文件上传</h4>
										</div>
										<form id="form_data"
											action="${pageContext.request.contextPath}/uploadMultiple"
											method="post" enctype="multipart/form-data">
											<div class="modal-body">
												<input type="hidden" name="userId"
													value="${sessionScope.existUser.userId }" /> <input
													type="file" name="attachment" multiple="multiple" />
											</div>
											<div class="modal-footer">
												<button type="button" class="btn btn-default"
													data-dismiss="modal">关闭</button>
												<button type="submit" onclick="add_info()"
													class="btn btn-primary">提交更改</button>
											</div>
										</form>
									</div>
								</div>
							</div>
							<span style="margin-left: 50px;">
								<button class="upload" data-toggle="modal"
									data-target="#addFolder" style="margin-left: 50px;">新建文件夹</button>

								<div class="modal fade" id="addFolder" tabindex="-1"
									role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
									<div class="modal-dialog">
										<div class="modal-content">
											<div class="modal-header">
												<button type="button" class="close" data-dismiss="modal"
													aria-hidden="true">&times;</button>
												<h4 class="modal-title" id="myModalLabel">新建文件夹</h4>
											</div>
											<form id="form_data"
												action="${pageContext.request.contextPath}/addFolder"
												method="post">
												<div class="modal-body">
													<input type="hidden" name="userId"
														value="${sessionScope.existUser.userId }" /> <input
														type="text" name="foleName" multiple="multiple"
														style="text-align: center" />
												</div>
												<div class="modal-footer">
													<button type="button" class="btn btn-default"
														data-dismiss="modal">关闭</button>
													<button type="submit" onclick="add_info()"
														class="btn btn-primary">提交</button>
												</div>
											</form>
										</div>
									</div>
								</div>
							</span>
							<span style="margin-left: 50px;">更多</span>
						</ul>
				</div>
				<a href="javascript:;" class="scm jian-a J_mainRight next"></a>
			</div>
			<!--读入首页-->
			<div class="ad-sub-nav-box content-tabs">
				<div class="ad-main-comment J_mainContent" id="ad-iframe">
					<iframe class="J_iframe" id="admin_iframeID" name="main"
						width="100%" height="100%" src="showFile?typeId=0" frameborder="0"
						data-id="showFile" seamless></iframe>
				</div>
			</div>
		</div>

	</div>
	</div>
	<script type="text/javascript"
		src="${pageContext.request.contextPath}/statics/js/jquery.min.js"></script>
	<script type="text/javascript"
		src="${pageContext.request.contextPath}/statics/js/contabs.js"></script>
	<script type="text/javascript"
		src="${pageContext.request.contextPath}/statics/js/maintabs.js"></script>
	<script type="text/javascript"
		src="${pageContext.request.contextPath}/statics/js/jquery-smartMenu-min.js"></script>
	<script type="text/javascript"
		src="${pageContext.request.contextPath}/statics/js/jquery.nicescroll.min.js"></script>
	<script type="text/javascript">
		$(function() {
			$(".ad-menu").niceScroll({
				cursorborder : "0 none",
				cursorcolor : "#1a1a19",
				cursoropacitymin : "0",
				boxzoom : false
			});
			/* 格式：$("#iframe的ID").contents().find("#iframe中的控件ID").click();  */
			/* 格式：$("#iframe的ID").contents().find("#iframe中的控件ID").click();//jquery 方法1 */
			/* 格式：$("#iframe中的控件ID",document.frames("frame的name").document).click();//jquery 方法2 */
			/* var $frame = $("#admin_iframeID").contents().find("#used_memoSizeID");
			console.log($frame.val()); */
			/* var mainFrame = document.getElementById('admin_iframeID').contentWindow.document; */
			/* console.log($('#admin_iframeID').contents().find("#used_memoSizeID").val()); */
		})
	</script>
</body>

</html>